<!DOCTYPE html>
<html>
<head>
    <title>视频播放</title>
    <style type="text/css">
        body {
            margin: 0;
            padding: 0px;
            font-family: "Microsoft YaHei", YaHei, "微软雅黑", SimHei, "黑体";
            font-size: 14px
        }
    </style>
    <script type="text/javascript" src="common/js/ckplayer.js"></script>
</head>
<body>

<div id="video" style="width: 900px; height: 600px;"></div>

<script type="text/javascript">
    var windowHeight = $(window).height()
    var windowWidth = $(window).width()
    if (windowWidth / windowHeight > 1.5) {//宽高比大于1.5
        //高度等于窗口高度
        $("#video").height(windowHeight)
        //宽度等于1.5倍的高度
        $("#video").height(windowHeight * 1.5)
    } else {
        //宽度等于窗口宽度
        $("#video").width(windowWidth)
        //高度等于1.5倍的宽度
        $("#video").height(windowWidth * 1.5)
    }
    var videoObject = {
        container: '#video', //容器的ID或className
        variable: 'player',//播放函数名称
        autoplay: true,//自动播放
        video: [//视频地址列表形式
            ["http://192.168.107.223:8081/video/play", 'video/mp4', '中文标清', 0]]
    };
    var player = new ckplayer(videoObject);
</script>
</body>
</html>